import request from '@/utils/request'

// 获取婚礼配置项
export function weddingConfig() {
	return request({
		'url': '/wedding/weddingConfig/1',
		'method': 'get'
	})
}
// 获取相册分类列表
export function listWeddingPhotoType(query) {
  return request({
    url: '/wedding/weddingPhotoType/list',
    method: 'get',
    params: query
  })
}
// 查询婚礼相册列表
export function listWeddingPhoto(query) {
  return request({
    url: '/wedding/weddingPhoto/list',
    method: 'get',
    params: query
  })
}


// 查询婚礼页面配置列表根据类型
export function listWeddingPage(type) {
  return request({
    url: '/wedding/weddingPage/listByType/'+type,
    method: 'get'
  })
}

// 查询婚礼相册分类详细
export function getWeddingPhotoType(id) {
  return request({
    url: '/wedding/weddingPhotoType/' + id,
    method: 'get'
  })
}

// 查询婚礼页面配置详细
export function getWeddingPage(id) {
  return request({
    url: '/wedding/weddingPage/' + id,
    method: 'get'
  })
}

// 查询婚礼祝福列表
export function listWeddingBless(query) {
  return request({
    url: '/wedding/weddingBless/list',
    method: 'get',
    params: query
  })
}

// 查询该用户是否已经祝福
export function exitsBlessByUserId(userId) {
  return request({
    url: '/wedding/weddingBless/exitsBlessByUserId/' + userId,
    method: 'get'
  })
}

// 新增婚礼祝福
export function addWeddingBless(data) {
  return request({
    url: '/wedding/weddingBless',
    method: 'post',
    data: data
  })
}

// 点赞婚礼祝福
export function dianzanWeddingBless(data) {
  return request({
    url: '/wedding/weddingBless/dianzan',
    method: 'post',
    data: data
  })
}